from rest_framework import serializers
from myapp.models import *

class UserSer(serializers.ModelSerializer):
    class Meta:
        model = User
        fields = '__all__'


# 建立序列化类
class CarouselSer(serializers.ModelSerializer):
    class Meta:
        model = Carousel
        fields = "__all__"


class GoodsSer(serializers.ModelSerializer):
    class Meta:
        model = Goods
        fields = "__all__"


class CategorySer(serializers.ModelSerializer):
    class Meta:
        model = Category
        fields = "__all__"
